﻿<html>

<head>
	<title>Data types and variables - Undefined / null / typeof</title>
	<link href="styles/js-console.css" rel="stylesheet" />
</head>

<body>
	<div id="js-console"></div>
	<script src="scripts/js-console.js"></script>
	<script>
		var x = 5;
		jsConsole.writeLine("x = " + x + ", typeof(x) = " + typeof(x));

		var x = 3.14159;
		jsConsole.writeLine("x = " + x + ", typeof(x) = " + typeof(x));
		
		x = undefined;
		jsConsole.writeLine("x = " + x + ", typeof(x) = " + typeof(x));
		
		x = null;
		jsConsole.writeLine("x = " + x + ", typeof(x) = " + typeof(x));

		x = 'hello';
		jsConsole.writeLine("x = " + x + ", typeof(x) = " + typeof(x));
		
		x = new Number(5);
		jsConsole.writeLine("x = " + x + ", typeof(x) = " + typeof(x));
	</script>
</body>

</html>
